<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Manuel S. Enverga University : Web-based Integrated Information System</title>
<link rel="shortcut icon" href="{dir_image}favicon.ico">
<link rel="stylesheet" type="text/css" href="{dir_css}Popup.css" />
<script type="text/javascript" src="{dir_js}jquery.min.js"></script>
<script type="text/javascript">
	<!--
	
	$(document).ready(function() {
		if ( $('#txtaccountno').val() == '' ) {
			accountNo('');
		}
		$('#txtaccess').on('change', function() {
			var account = $(this).val();
			accountNo(account);
		});
	});	
	
	function accountNo(strAccount) {
		
		var a;
		var m = $('#m').val();
		var d = $('#d').val();
		var y = $('#y').val();
		if ( strAccount == '' ) {
			a = 'A' + y + '-' + m + '-' + d;
		}
		else if ( strAccount == 'P' ) {
			a = 'F' + y + '-' + m + '-' + d;
		}
		else {
			a = strAccount + y + '-' + m + '-' + d;
		}
		
		$('#txtaccountno').val(a);
			
	}
</script>
</head>
<body>
	<div class="title-frame">Account Information</div>
	<input type="hidden" id="showDept" value="{show_dept}"/>
	<input type="hidden" id="m" value="{m}"/>
	<input type="hidden" id="d" value="{d}"/>
	<input type="hidden" id="y" value="{y}"/>
	<form method="post" enctype="multipart/form-data" action="">
		<table width="480" border="0" cellspacing="0" cellpadding="0">
			<tr>
				<td height="28">Access Level<span class="required-field">*</span></td>
				<td>:</td>
				<td>
					<select name="txtaccess" id="txtaccess" class="select-month-input" {w_access}>
						<option value="A" {selectedA}>Administrator</option>
						<option value="R" {selectedR}>Registrar</option>
						<option value="D" {selectedD}>Dean</option>
						<option value="P" {selectedP}>Faculty</option>
					</select>
				</td>
			</tr>
			<tr class="display-none" id="departmentTr">
				<td height="28">Department<span class="required-field">*</span></td>
				<td>:</td>
				<td>{department_list}</td>
			</tr>
			<tr>
				<td height="8" colspan="3"></td>
			</tr>
			<tr>
				<td width="130" height="28">Account #</td>
				<td width="10">:</td>
				<td width="350"><input type="text" name="txtaccountno" id="txtaccountno" class="text-input" value="{txtaccountno}" {w_txtaccountno}/></td>
			</tr>
			<tr>
				<td height="28">First Name<span class="required-field">*</span></td>
				<td>:</td>
				<td><input type="text" name="txtfname" class="text-input" value="{txtfname}" {w_txtfname}/></td>
			</tr>
			<tr>
				<td height="28">Middle Name</td>
				<td>:</td>
				<td><input type="text" name="txtmname" class="text-input" value="{txtmname}" {w_txtmname}/></td>
			</tr>
			<tr>
				<td height="28">Last Name<span class="required-field">*</span></td>
				<td>:</td>
				<td><input type="text" name="txtlname" class="text-input" value="{txtlname}" {w_txtlname}/></td>
			</tr>
			<tr>
				<td height="28">Birthdate</td>
				<td>:</td>
				<td>
				<select name="txtbdatemm" id="txtbdatemm" class="select-month-input" {w_txtbdatemm}>
					<option value="">--- Month ---</option>
					<option value="01" {selected01}>January</option>
					<option value="02" {selected02}>February</option>
					<option value="03" {selected03}>March</option>
					<option value="04" {selected04}>April</option>
					<option value="05" {selected05}>May</option>
					<option value="06" {selected06}>June</option>
					<option value="07" {selected07}>July</option>
					<option value="08" {selected08}>August</option>
					<option value="09" {selected09}>September</option>
					<option value="10" {selected10}>October</option>
					<option value="11" {selected11}>November</option>
					<option value="12" {selected12}>December</option>
				</select>
				<input type="text" class="select-day-input" name="txtbdatedd" id="txtbdatedd" value="{txtbdatedd}" maxlength="2" {w_txtbdatedd}/>
				<input type="text" class="select-year-input" name="txtbdateyy" id="txtbdateyy" value="{txtbdateyy}" maxlength="4" {w_txtbdateyy}/>
				
				</td>
			</tr>
			<tr>
				<td height="28">Gender</td>
				<td>:</td>
				<td>
					<select name="txtgender" class="select-month-input" {w_txtgender}>
						<option value="">--- Gender ---</option>
						<option value="male" {selectedmale}>Male</option>
						<option value="female" {selectedfemale}>Female</option>
					</select>
				</td>
			</tr>
			<tr>
				<td height="28">E-mail Addres</td>
				<td>:</td>
				<td><input type="text" name="txtemail" class="text-input" value="{txtemail}" {w_txtemail}/></td>
			</tr>
			<tr>
				<td height="28">Contact #</td>
				<td>:</td>
				<td><input type="text" name="txtcontact" class="text-input" value="{txtcontact}"/></td>
			</tr>
			<tr>
				<td height="28">Home Address</td>
				<td>:</td>
				<td><input type="text" name="txtaddress" class="text-input" value="{txtaddress}"/></td>
			</tr>
			<tr>
				<td height="28">Guardian</td>
				<td>:</td>
				<td><input type="text" name="txtguardian" class="text-input" value="{txtguardian}"/></td>
			</tr>
			<tr>
				<td height="8" colspan="3"><span class="required-field">{udpate_user_pass}</span></td>
			</tr>
			<tr>
				<td height="28">Username<span class="required-field">*</span></td>
				<td>:</td>
				<td><input type="text" name="txtusername" class="text-input" value="{txtusername}" {w_txtusername}/></td>
			</tr>
			<tr>
				<td height="28">Password<span class="required-field">*</span></td>
				<td>:</td>
				<td><input type="password" name="txtpassword" class="text-input" value="" {w_txtpassword}/></td>
			</tr>
			<tr>
				<td height="28"></td>
				<td></td>
				<td><input type="submit" name="subButton" class="submit-input" value="Save"/> <span class="record-saved-color">{saved_record}</span></td>
			</tr>
		</table>
	</form>
</body>
</html>
